import request from '@/utils/request'

// 查询试题列表
export function topicList(query) {
  return request({
    url: '/study/topic/list',
    method: 'get',
    params: query
  })
}
// 新增试题
export function addTopic(data) {
  return request({
    url: '/study/topic',
    method: 'post',
    data: data
  })
}


// 获取试题详细信息
export function topicId(id) {
  return request({
    url: `/study/topic/${id}`,
    method: 'get',
  })
}


// 修改试题
export function eitHtopic(data) {
  return request({
    url: '/study/topic',
    method: 'put',
    data: data
  })
}

// 删除试题
export function delTopic(id) {
  return request({
    url: `/study/topic/${id}`,
    method: 'delete'
  })
}

// 导出品类列表
export function exporTtopic(data) {
  return request({
    url: '/study/topic/export',
    method: 'post',
    data: data
  })
}

// 审核试题
export function topicAudit(query) {
  return request({
    url: '/study/topic/audit',
    method: 'get',
    params: query
  })
}